﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using EntitiesContainer.Entities;
using EntitiesContainer.Interfaces;

namespace DAL.Repository
{
    class ProductCategoryRepository : BaseRepotory<ProductCategory>, IProductCategoryRepository
    {
        public ProductCategoryRepository(IDbContext context)
            : base(context)
        {
 
        }
        public List<string> GetAllCategories()
        {
        List<string> categories = new List<string>();
        foreach (var item in _context.Set<ProductCategory>())
        {
            categories.Add(item.Name);
        }
            return categories;
        }
        
    }
}
